<template>
    <el-card class="box-card">
        <div class="top">
        <div v-if="title" class="title">{{title}}</div>
         <slot name="right"></slot>
        </div>
        <slot></slot>
    </el-card>
</template>
<script>
    export default {
        name:"MyCard",
        props:{
          title:{
              type:String,
              default:""
          }
        },
        methods: {

        }
    }
</script>
<style lang="scss" scoped>
    ::v-deep.el-card{
        width: 100%;
        display:inline-block;
        .title{
            font-weight: 600;
            font-size: 18px;
            margin-left: 5px;
            padding: 5px 0 15px 0;
        }
        .top{
            display: flex; justify-content: space-between; align-items: center
        }
    }

</style>
